package cn.walls1717.wallsmall.seckill.config;

/**
 * sentinel配置类
 *
 * @author walls1717
 * @since 2022/11/28 13:14
 **/
/*@Configuration
public class SentinelConfig {

    public SentinelConfig() {
        WebCallbackManager.setUrlBlockHandler((httpServletRequest, httpServletResponse, e) -> {
            R r = R.error(TOO_MANY_REQUEST_EXCEPTION.getCode(), TOO_MANY_REQUEST_EXCEPTION.getMsg());
            httpServletResponse.setCharacterEncoding("UTF-8");
            httpServletResponse.setContentType("application/json");
            httpServletResponse.getWriter().write(JSON.toJSONString(r));
        });
    }
}*/
